home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 1 / Cream of the Crop 1.iso / PROGRAM / FDF101.ARJ / ELIB.ZOO / ftimes.c < prev    next >
C/C++ Source or Header  |  1992-04-30  |  458b  |  15 lines

  1. #include <dir.h>
  2.  
  3. /*
  4.  * cmptime
  5.  *
  6.  * given two files, return positive if the first has a more recent modification
  7.  * date/time, zero if the files have the same modification date/time or
  8.  * negative if the second is more recent.
  9.  */
  10. long cmptime(const struct ffblk *a, const struct ffblk *b)
  11. {
  12.     return (((unsigned long)a->ff_fdate) << 16 | (unsigned long)a->ff_ftime) -
  13.            (((unsigned long)b->ff_fdate) << 16 | (unsigned long)b->ff_ftime);
  14. }
  15.